package com.netflexitysolutions.amazonws.ec2.internal.operations;

import com.amazonaws.ec2.doc._2009_04_04.DeleteVolumeType;
import com.netflexitysolutions.amazonws.ec2.EC2;

public class DeleteVolumeOperation extends SingleObjectOperationExecutor<DeleteVolumeType, Boolean> {

	public DeleteVolumeOperation(EC2 ec2, String volumeId) {
		super(ec2, volumeId);
	}

	@Override
	protected Boolean call(DeleteVolumeType request) {
		request.setVolumeId(objectId);
		return getEC2().getService().deleteVolume(request).isReturn();
	}

}
